<template>
  <view class="viewer">
    <view class="card-button" @click="toLink('acountBind')">
      <span class="c-title">账号绑定</span>
      <image style="width: 12rpx; height: 16rpx" src="../../static/icons/icon-more.png" mode="widthFix" />
    </view>
    <view class="card-button" @click="toLink('a')">
      <span class="c-title">隐私政策</span>
      <image style="width: 12rpx; height: 16rpx" src="../../static/icons/icon-more.png" mode="widthFix" />
    </view>
  </view>
</template>

<script setup>
  const toLink = (type) => {
    if (type == 'a') {
      uni.navigateTo({ url: '/pages/agreement/privacy' })
    } else if (type == 'b') {
      uni.navigateTo({ url: '/pages/agreement/user' })
    } else if (type == 'acountBind') {
      uni.navigateTo({ url: '/pages/my/acount-bind' })
    }
  }
</script>

<style lang="scss">
  page {
    height: 100%;
    overflow: hidden;
    background-color: #f7f8fa;
  }
  .viewer {
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    height: 100%;
  }
  .card-button {
    margin-top: 24rpx;
    width: calc(100% - 48rpx);
    height: 140rpx;
    background-color: #ffffff;
    border-radius: 8rpx;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24rpx;
    .c-title {
      color: #191c27;
      flex: 1;
      font-size: 32rpx;
    }
  }
</style>
